import http from '@/utils/http'
const env = import.meta.env
const BASE_URL = env.PROD ? `${env.VITE_API_BASE_URL}/api/v1` : '/api/v1'
/** @desc 发圈 - 列表 */
export function momentList(data: any) {
  return http.get(`${BASE_URL}/moment/list`, data)
}

/** @desc 发圈 - 更新 */
export function momentUpdate(data: any) {
  return http.post(`${BASE_URL}/moment/update`, data)
}

/** @desc 发圈 - 创建 */
export function momentCreate(data: any) {
  return http.post(`${BASE_URL}/moment/create`, data)
}

/** @desc 发圈 - 商品预览 */
export function momentPreviewForGoods(data: any) {
  return http.post(`${BASE_URL}/moment/preview`, data)
}

/** @desc 发圈 -文案预览 */
export function momentPreviewForCopywriting(data: any) {
  return http.post(`${BASE_URL}/moment/msgPreview`, data)
}

/** @desc 发圈 - 统计顶部数据 */
export function momentStatisticsTotalData(data: any) {
  return http.post(`${BASE_URL}/moment/statistics/totalData`, data)
}

/** @desc 发圈 -统计折线图数据 */
export function momentStatisticsGraphData(data: any) {
  return http.post(`${BASE_URL}/moment/statistics/graphData`, data)
}
